/**
 * 
 */
package map.model;

import org.w3c.dom.Element;

/**
 * @author balage
 *
 */
public class MapNode extends MapItem {

	public final double lat;
	public final double lon;
	//public final long id;
	
	public MapNode(Element node) {
		super(node);
		lat = Double.valueOf(node.getAttribute("lat")).doubleValue();
		lon = Double.valueOf(node.getAttribute("lon")).doubleValue();
		//id = Long.valueOf(node.getAttribute("id")).longValue();
	}

	@Override
	public boolean equals(Object obj) {
		if (obj instanceof MapNode){
			return ((MapNode) obj).id == this.id;
		}
		return super.equals(obj);
	}
	
}
